home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 7932 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.9 KB

  1. Path: solon.com!not-for-mail
  2. From: seebs@solutions.solon.com (Peter Seebach)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: #include --> Question
  5. Date: 29 Feb 1996 12:54:50 -0600
  6. Organization: Usenet Fact Police (Undercover)
  7. Message-ID: <4h4spq$c68@solutions.solon.com>
  8. References: <4gvp2c$sdr$1@mhafc.production.compuserve.com> <4h1d2l$4n3@pyrrhus-f.hrz.tu-chemnitz.de> <4h2si8$1bf@solutions.solon.com> <31359A05.4014@iadfw.net>
  9. NNTP-Posting-Host: solutions.solon.com
  10.  
  11. In article <31359A05.4014@iadfw.net>, Larry Weiss  <lfw@iadfw.net> wrote:
  12. >Peter Seebach wrote:
  13. >> The character '\' introduces undefined behavior in a header file name.
  14.  
  15. >Peter, are you sure about this?   Can you cite a clause of the Standard?
  16.  
  17. >I'm looking at Clause 6.8.2 and 6.1.7.  The only characters that cannot be
  18. >used in a #include "name" header name according to those sections are
  19. >newline and doublequote.     
  20.  
  21. (Because all of the relevant quoting characters are being discussed, I will
  22. use q for quotes.)
  23.  
  24. Ahh, but you must also read the paragraph below that (also 6.1.7), which
  25. states that if the characters q'q, q\q, or q/*q occur between the q"q
  26. delimiters, the behavior is undefined.  (Between q<q and q>q, q"q also
  27. introduces undefined behavior.)
  28.  
  29. There's a footnote (25) attached to this - "Thus, sequences of characters that
  30. resemble esqape sequences cause undefined behavior."
  31.  
  32. (Yes, footnotes are not binding, but the conclusion is obviously valid.)
  33.  
  34. I object slightly to using /* as a "character", but no big complaints.
  35.  
  36. >Of course, all interpretation of the characters used to signify a
  37. > #include "name" are implementation defined.
  38.  
  39. Yes.
  40.  
  41. -s
  42. -- 
  43. Peter Seebach - seebs@solon.com - Copyright 1996 Peter Seebach.
  44. C/Unix wizard -- C/Unix questions? Send mail for help.  No, really!
  45. FUCK the communications decency act.  Goddamned government.  [literally.]
  46. The *other* C FAQ - http://www.solon.com/~seebs/c/c-iaq.html
  47.